<html>
    <head>
        <meta http-equiv="content-type" content="text/html; charset=utf-8">
        <title>Js插件</title>
        <script src="./Js/jquery-1.8.3.min.js" type="text/javascript" charset="utf-8"></script>
        <style type="text/css">
           
        </style>
    </head>
    <body>
        <div id="main"><a href="javascript:showBg();">点击这里查看效果</a> 
        <div id="fullbg"></div> 
        <!-- 外层大框 -->
        <div id="dialog"> 
        <p class="close"><a href="#" onclick="closeBg();">关闭</a></p> 
        <div><textarea></textarea></div> 
        </div> 
        </div> 
    </body>
    <script type="text/javascript"> 
//显示灰色 jQuery 遮罩层 
function showBg() { 
var bh = $("body").height(); 
var bw = $("body").width(); 
$("#fullbg").css({ 
height:bh, 
width:bw, 
display:"block" 
}); 
$("#dialog").show(); 
} 
//关闭灰色 jQuery 遮罩 
function closeBg() { 
$("#fullbg,#dialog").hide(); 
} 
</script>
</html>


